import { ResPage } from "@/api/interface/index";
import { BASE } from "@/api/config/servicePort";
import http from "@/api";

/**
 * @name Ucenter
 */
// 获取告警数据
export const getAlarmEchartsApi = params => {
  return http.post<ResPage<any>>(`${BASE}/proxy/${sessionStorage.getItem("sysId")}/alarmrs/fullFault/echart`, params);
};
// 获取第三方id
export const getThirdIdList = params => {
  return http.get<ResPage<any>>(BASE + `/third_system/`, params);
};

// // 获取告警列表
// const _getAlarmData = params => {
//   return fetch(`/service/api/proxy/${sessionStorage.getItem('sysId')}/vdi/rest/workspace/realtimeAlarms/list`, 'get', {}, params)
// }
// 获取网络设备实时监控数据
export const getNetEquipLatestApi = params => {
  return http.get<ResPage<any>>(`${BASE}/proxy/${sessionStorage.getItem("sysId")}/perfrs/perf/data/device/latest`, params);
};
// 获取网络设备历史监控数据
export const getNetEquipRangeApi = params => {
  return http.get<ResPage<any>>(`${BASE}/proxy/${sessionStorage.getItem("sysId")}/perfrs/perf/data/device/range`, params);
};
// 获取告警总览数据
export const getAlarmOverviewApi = () => {
  return http.get<ResPage<any>>(`/alarm/api/overview/ucenter/`);
};
